import request from '@/utils/request'

// 获取食品列表
export function reqFoodList(offset,limit,restaurant_id){
    return request({
        url:`/shopping/v2/foods?offset=${offset}&limit=${limit}&restaurant_id=${restaurant_id}`,
        method:'get'
    })
}

// 获取食品种类详情
export function reqFoodCategory(category_id){
    return request({
        url:`/shopping/v2/menu/${category_id}`,
        method:'get',
        // params:category_id
    })
}

// 获取餐馆详情
export function reqShopDetail(shopid){
    return request({
        url:`/shopping/restaurant/${shopid}`,
        method:'get'
    })
}

// 更新食品信息
export function reqUpDateFoodDetail(data){
    // console.log(data)
    // ({
    //     url:'/shopping/v2/updatefood',
    //     method:'post',
    //     data
    // })
    return request.post('/shopping/v2/updatefood',data)
}

